<?php
$title = 'Tableau de bord';
$this->headTitle($title);
//echo '<pre>';
//print_r($produits);
//echo '</pre>';
//var_dump($stylesssFamilles);
$this->headScript()->prependFile($this->basePath()."/js/foam/moment.min.js");
?>
<script type="text/javascript">
    $('document').ready(function(){        
        showMe('synthese', '');
        
        $('#a-month-detail').editable({
            placement: 'bottom',
            format: 'YYYY-MM-DD',    
            viewformat: 'MMMM YYYY',    
            template: 'MMMM YYYY',
            combodate: {
                minYear: 2000,
                maxYear: 2030,
                minuteStep: 1
            }
        });  
        
        $('#a-month1-retro').editable({
            placement: 'bottom',
            format: 'YYYY-MM-DD',    
            viewformat: 'MMMM YYYY',    
            template: 'MMMM YYYY',
            combodate: {
                minYear: 2000,
                maxYear: 2030,
                minuteStep: 1
            }
        });
        
        $('#a-month2-retro').editable({
            placement: 'left',
            format: 'YYYY-MM-DD',    
            viewformat: 'MMMM YYYY',    
            template: 'MMMM YYYY',
            combodate: {
                minYear: 2000,
                maxYear: 2030,
                minuteStep: 1
            }
        });
        
        $("#a-month-detail").editable('option','disabled',true);
        $("#a-month1-retro").editable('option','disabled',true);
        $("#a-month2-retro").editable('option','disabled',true);
    });
</script>
<div class="content-head">
    <h3><?php echo $title; ?></h3>
</div>
<div class="content-body">
    <table width="100%">
        <tr>
            <td colspan="2" class="content-body-top">
                <table width="100%" border="1">
                    <tr>
                        <td width="10%" class="td-selection">Séléction</td>
                        <td width="20%" class="td-defaut">
                            <label onclick="checkMe(this, 'synthese')"><input type="checkbox" class="styled" checked="checked" /> par défaut</label>                            
                        </td>
                        <td width="30%" class="td-detail">
                            <label onclick="checkMe(this, 'detail')"><input type="checkbox" class="styled" /> détail carte: </label>
                            <a id="a-month-detail"
                                data-name="month"
                                data-type="combodate"
                                data-value="<?php echo Date('Y-m-d'); ?>"></a>
                        </td>
                        <td width="40%" class="td-mois">
                            <label onclick="checkMe(this, 'retro')"><input type="checkbox" class="styled" /> mois de la carte à afficher</label>
                            <a id="a-month1-retro"
                                data-name="month1"
                                data-type="combodate"
                                data-value="<?php echo Date('Y-m-d'); ?>"></a>
                            <a id="a-month2-retro"
                                data-name="month2"
                                data-type="combodate"
                                data-value="<?php echo Date('Y-m-d'); ?>"></a>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr class="content-body-bottom">
            <td class="loading" style="text-align: center; padding: 20px">
                <img src="<?php echo $this->basePath() . '/img/foam/loader.gif'; ?>" alt="loading" />
            </td>
        </tr>
    </table>
</div>